package lianxi;

import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.SQLException;

import com.DBUtil;

public class _03_ {

	public static void main(String[] args) throws ClassNotFoundException, SQLException {
		Connection connection = DBUtil.getConnection();
		String sql = "delete from t_goods where name = '格力空调';";
		PreparedStatement preparedStatement = connection.prepareStatement(sql);
		int count = preparedStatement.executeUpdate(sql);
		System.out.println(count);
		DBUtil.close(preparedStatement);
		DBUtil.close(connection);
	}

}
